package com.hzsai.mininote.tester;

import com.hzsai.mininote.entity.Food;
import com.hzsai.mininote.entity.SexEnum;
import com.hzsai.mininote.exception.InvalidBoundaryException;

/**
 * @author hzsai
 * @date 2020/1/7 21:47
 * @usage:
 */
public class FoodEnumTester {

    public static void main(String[] args) throws InvalidBoundaryException {

        SexEnum man = SexEnum.MALE;
        System.out.println(SexEnum.getEnumById(2));

        for (Food.Coffee coffee : Food.Coffee.values()) {
            System.out.println(coffee + " ");
        }

        for (Food.Fruit fruit : Food.Fruit.values()) {
            System.out.println(fruit + " ");
        }

        Food seafood = Food.Fruit.A_FRUIT;

        System.out.println(seafood);

        seafood = Food.Coffee.B_COFFEE;

        System.out.println(seafood);
    }
}
